import React, { Component } from 'react'
import PubSub from 'pubsub-js'
export default class Son1 extends Component {
  componentDidMount() {
    //订阅
    // 返回值就是当前这一次订阅的id
    const subId = PubSub.subscribe('howFindMoney', (topic, data) => {
      console.log('son1', data)
    })
  }
  render() {
    return <div>Son1</div>
  }
}
